package com.xiaomili.halfsugar.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import java.util.List;

/**
 * 搜索 ---单品、清单的碎片适配器
 * Created by Administrator on 2016/7/15.
 */
public class SearchHomepageVP_Adapter extends FragmentPagerAdapter {
    private List<Fragment>mList;

    public SearchHomepageVP_Adapter(FragmentManager fm, List<Fragment>list) {
        super(fm);
        this.mList=list;
    }

    @Override
    public Fragment getItem(int position) {
        return mList.get(position);
    }

    @Override
    public int getCount() {
        return mList.size();
    }
}
